﻿#ifndef ABSTRACTCONTAINEDWIDGET_H
#define ABSTRACTCONTAINEDWIDGET_H

#include <QWidget>
#include <QMainWindow>

class IContainedWidget
{
public:
    virtual ~IContainedWidget() {}
    virtual QPixmap icon() const = 0;
    virtual QString name() const = 0;
};

class AbstractContainedWidget : public QWidget, public IContainedWidget
{
    Q_OBJECT
public:
    explicit AbstractContainedWidget(QWidget *parent = nullptr) :
        QWidget(parent)
    {

    }
};

class AbstractContainedWindow : public QMainWindow, public IContainedWidget
{
    Q_OBJECT
public:
    explicit AbstractContainedWindow(QWidget *parent = nullptr, Qt::WindowFlags flags = Qt::WindowFlags()) :
        QMainWindow(parent, flags)
    {

    }
};

#endif // ABSTRACTCONTAINEDWIDGET_H
